//
//  main.m
//  MyProtocol
//
//  Created by gzjd on 2017/5/6.
//  Copyright © 2017年 gzjd. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "MyTest.h"
#import "MyProtocol.h"
int main(int argc, const char * argv[]) {
    
    @autoreleasepool {
        // insert code here...
        NSLog(@"Hello, World!");
        MyTest *myTest=[[MyTest alloc]init];
        [myTest showInfo];
        
        
        [myTest release];
        SEL sel=@selector(print:);
        if([myTest respondsToSelector:sel ])
            [myTest print:20];
        
        [myTest printValue:10 andValue:20];
        id<MyProtocol> myProtocol=[[MyTest alloc]init];
        if([myProtocol respondsToSelector:@selector(print:)])
            [myProtocol print:102];
        [myProtocol printValue:103 andValue:105];
        [myProtocol release];
        
    }
    
    return 0;
}
